<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <style>
        li {
            list-style:none;
            background-color: grey;
            width: 50px;
            height: 50px;
            margin: auto;
            margin-top: 10px;
            border-radius: 50%;
        }

        .s1 li:nth-child(1){
            background-color: red;
        }
        .s2 li:nth-child(2){
            background-color: yellow;
        }
        .s3 li:nth-child(3){
            background-color: green;
        }
    </style>
</head>
<body>

<ul id="traffic">
    <li></li>
    <li></li>
    <li></li>
</ul>

<!--<script src="traffic1.js"></script>-->
<!--<script src="traffic2.js"></script>-->
<!--<script src="traffic3.js"></script>-->
<script src="traffic4.js"></script>
</body>
</html>